﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using Bird.Core.Infrastructure;
using Ninject.Web.Common;
using Ninject.Parameters;
using Ninject;
namespace Bird.Core.Infrastructure.DependencyManagement
{
    public class ContainerManager
    {
        Ninject.IKernel _kernel;


        public ContainerManager(Ninject.IKernel kernel)
        {
            _kernel = kernel;
        }

        public object Resolve(Type type)
        {
            return _kernel.TryGet(type);
        }

        public IEnumerable<object> ResolveAll(Type type)
        {
            return _kernel.GetAll(type);
        }

    }
}